package com.example.shaomengjie.smvp.net.api;

import com.example.shaomengjie.smvp.bean.GuideBean;
import com.example.shaomengjie.smvp.bean.TestBean;
import com.example.shaomengjie.smvp.bean.UserBean;

import java.util.List;

import io.reactivex.Observable;
import retrofit2.http.Field;
import retrofit2.http.FormUrlEncoded;
import retrofit2.http.POST;
import retrofit2.http.Query;


public interface ApiService {

    @FormUrlEncoded
    @POST("query?key=7c2d1da3b8634a2b9fe8848c3a9edcba")
    Observable<ApiResponse<TestBean>> getDatas(@Field("pno") int pno, @Field("ps") int ps, @Field("dtype") String dtype);

    @POST("/api/appAccount/login")
    Observable<ApiResponse<UserBean>> requestLogin(@Query("username") String username, @Query("password") String password);

    @POST("/api/appAdvertising/queryAdvertising")
    Observable<ApiResponse<List<GuideBean>>> requesetGuide(@Query("mobile_type") String mobile_type);
}
